package com.woniu.darryringmall.admin.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.woniu.darryringmall.admin.entity.Manager;
import com.woniu.darryringmall.admin.entity.Perm;
import com.woniu.darryringmall.admin.mapper.ManagerMapper;
import com.woniu.darryringmall.admin.service.ManagerService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 管理员service实现类
 */
@Service
public class ManagerServiceImpl extends ServiceImpl<ManagerMapper, Manager> implements ManagerService{
    @Autowired
    private ManagerMapper managerMapper;

    @Override
    public Manager getByAccount(String name) {
        return managerMapper.getByAccount(name);
    }

    @Override
    public List<Perm> getPermsByManagerId(int id) {
        return managerMapper.getPermsByManagerId(id);
    }
}
